﻿using System;
using System.Linq;
using System.Collections.Generic;
using System.Text;
using SkynetCE.Foundation.Services.SkynetService;
using SkynetCE.Foundation.Services.Navigation;
using SkynetCE.Foundation.Model;

namespace SkynetCE.Administration.Views.MgmExams
{
    public class MgmExamPresenter : Foundation.Views.Master.MasterPresenter<IMgmExamView>
    {
        public ISkynetService  SkynetService { protected  get; set; }


        public MgmExamPresenter()
        {
            this.SkynetService = NavigationService.ResolveService<ISkynetService>();
        }
        public override void OnViewReady()
        {
            this.View.Categories = this.SkynetService.GetCategories();            
        }

        internal void InsertExam(Exam item )
        {
            this.SkynetService.RegisterExam(item);  
        }
    }
}
